﻿using System;
using System.Collections.Generic;
using System.Text;
using System.Windows.Browser;
using System.Windows.Media;

namespace MapServiceAPI
{
    public class Polygon : MapShapes
    {
        LatLng[] points;
        Color strokeColor;
        int strokeWeight;
        double strokeOpacity;
        Color fillColor;
        double fillOpacity;

        public Polygon(LatLng[] points, Color strokeColor, int strokeWeight, double strokeOpacity, Color fillColor, double fillOpacity)
        {
            this.strokeColor = strokeColor;
            this.strokeWeight = strokeWeight;
            this.strokeOpacity = strokeOpacity;
            this.fillColor = fillColor;
            this.fillOpacity = fillOpacity;
            this.points = points;
            Redraw();
        }

        public override void Redraw()
        {
            MapServiceJS.Instance.ShapePolygon(this, points, strokeColor, strokeWeight, strokeOpacity, fillColor, fillOpacity);
            base.Redraw();
        }
    }

}
